using SharePointUtilitiesForDevelopers.Mapper;

namespace SharePointUtilitiesForDevelopers.Gateway
{
    /// <summary>
    /// Defines the interface for a gateway to the SharePoint site data service.
    /// </summary>
    public interface ISharePointSiteDataServiceGateway
    {
        /// <summary>
        /// Gets the web.
        /// </summary>
        /// <typeparam name="TDomainObject">The type of the domain object.</typeparam>
        /// <param name="siteUrl">The URL.</param>
        /// <param name="mapper">The mapper.</param>
        /// <returns>A <see cref="TDomainObject"/>.</returns>
        TDomainObject GetWeb<TDomainObject>(
            string siteUrl,
            IMapper<SharePointSiteData, TDomainObject> mapper);
    }
}